package com.dao;

import com.exception.MallException;
import com.pojo.User;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface UserMapper {
    int deleteByPrimaryKey(Integer id);
    User selectByPrimaryKey(Integer id);

    User selectByName(String username);
    int insert(User record);
    int insertSelective(User user);

    User selectLogin(@Param("username") String username, @Param("password") String password);
    int updateByPrimaryKey(User record);
    int updateByPrimaryKeySelective(User user);


    List<User> AdminListForUser();

}
